#ifndef _FXFM_CODEPAGE_H_
#define _FXFM_CODEPAGE_H_

//*****************************************************************************
//* Code pages
//*****************************************************************************
//macros for code pages
#define FXFM_CODEPAGE_DefANSI					0		//default ANSI code page
#define FXFM_CODEPAGE_DefOEM					1		//default OEM code page
#define FXFM_CODEPAGE_DefMAC					2		//default MAC code page
#define FXFM_CODEPAGE_Thread					3		//Current thread ANSI code page
#define FXFM_CODEPAGE_Symbol					42		//Symbol
#define FXFM_CODEPAGE_MSDOS_US					437		//United States, IBM PC
#define FXFM_CODEPAGE_Arabic_ASMO708			708		//Arabic (ASMO 708)
#define FXFM_CODEPAGE_Arabic_ASMO449Plus		709		//Arabic (ASMO 449+, BCON V4)
#define FXFM_CODEPAGE_Arabic_Transparent		710		//Arabic (transparent Arabic)
#define FXFM_CODEPAGE_Arabic_NafithaEnhanced	711		//Arabic (Nafitha Enhanced)
#define FXFM_CODEPAGE_Arabic_TransparentASMO	720		//Arabic (transparent ASMO)
#define FXFM_CODEPAGE_MSDOS_Greek1				737		//Greek
#define FXFM_CODEPAGE_MSDOS_Baltic				775		//Baltic
#define FXFM_CODEPAGE_MSWin31_WesternEuropean	819		//Windows 3.1 (United States and Western Europe)
#define FXFM_CODEPAGE_MSDOS_WesternEuropean		850		//Multilingual Latin 1 (Western European)
#define FXFM_CODEPAGE_MSDOS_EasternEuropean		852		//Multilingual Latin 2 (Eastern European)
#define FXFM_CODEPAGE_MSDOS_Latin3				853		//Multilingual Latin 3
#define FXFM_CODEPAGE_MSDOS_Cyrillic			855		//Cyrillic
#define FXFM_CODEPAGE_MSDOS_Turkish				857		//Multilingual Latin 5 (Turkish)
#define FXFM_CODEPAGE_MSDOS_Latin1Euro			858		//Multilingual Latin 1 + Euro Sign
#define FXFM_CODEPAGE_MSDOS_Portuguese			860		//Portuguese
#define FXFM_CODEPAGE_MSDOS_Icelandic			861		//Icelandic
#define FXFM_CODEPAGE_MSDOS_Hebrew				862		//Hebrew
#define FXFM_CODEPAGE_MSDOS_FrenchCanadian		863		//French Canadian
#define FXFM_CODEPAGE_MSDOS_Arabic				864		//Arabic
#define FXFM_CODEPAGE_MSDOS_Norwegian			865		//Norwegian
#define FXFM_CODEPAGE_MSDOS_Russian				866		//Russian
#define FXFM_CODEPAGE_MSDOS_Greek2				869		//Greek
#define FXFM_CODEPAGE_MSDOS_Thai				874		//Thai
#define FXFM_CODEPAGE_MSDOS_KamenickyCS			895		//Kamenicky CS
#define FXFM_CODEPAGE_ShiftJIS					932		//Japanese (Shift-JIS)
#define FXFM_CODEPAGE_ChineseSimplified			936		//Chinese Simplified (GBK)
#define FXFM_CODEPAGE_Korean					949		//Korean
#define FXFM_CODEPAGE_ChineseTraditional		950		//Chinese Traditional (Big5)
#define FXFM_CODEPAGE_UTF16LE					1200	//Unicode (UTF-16 Little endian)
#define FXFM_CODEPAGE_UTF16BE					1201	//Unicode (UTF-16 Big endian)
#define FXFM_CODEPAGE_MSWin_EasternEuropean		1250	//Eastern European (Windows)
#define FXFM_CODEPAGE_MSWin_Cyrillic			1251	//Cyrillic (Windows)
#define FXFM_CODEPAGE_MSWin_WesternEuropean		1252	//Western European (Windows)
#define FXFM_CODEPAGE_MSWin_Greek				1253	//Greek (Windows)
#define FXFM_CODEPAGE_MSWin_Turkish				1254	//Turkish (Windows)
#define FXFM_CODEPAGE_MSWin_Hebrew				1255	//Hebrew (Windows)
#define FXFM_CODEPAGE_MSWin_Arabic				1256	//Arabic (Windows)
#define FXFM_CODEPAGE_MSWin_Baltic				1257	//Baltic (Windows)
#define FXFM_CODEPAGE_MSWin_Vietnamese			1258	//Vietnamese (Windows)
#define FXFM_CODEPAGE_Johab						1361	//Korean (Johab)
#define FXFM_CODEPAGE_MAC_Roman					10000	//MAC Roman
#define FXFM_CODEPAGE_MAC_ShiftJIS				10001	//MAC Shift JIS
#define FXFM_CODEPAGE_MAC_ChineseTraditional	10002	//MAC Big5
#define FXFM_CODEPAGE_MAC_Korean				10003	//MAC Korean
#define FXFM_CODEPAGE_MAC_Arabic				10004	//MAC Arabic
#define FXFM_CODEPAGE_MAC_Hebrew				10005	//MAC Hebrew
#define FXFM_CODEPAGE_MAC_Greek					10006	//MAC Greek
#define FXFM_CODEPAGE_MAC_Cyrillic				10007	//MAC Cyrillic
#define FXFM_CODEPAGE_MAC_ChineseSimplified		10008	//MAC Chinese Simplified (GBK)
#define FXFM_CODEPAGE_MAC_Thai					10021	//MAC Thai
#define FXFM_CODEPAGE_MAC_EasternEuropean		10029	//MAC Eastern European (Latin 2)
#define FXFM_CODEPAGE_MAC_Turkish				10081	//MAC Turkish
#define FXFM_CODEPAGE_UTF32LE					12000	//Unicode (UTF-32 Little endian)
#define FXFM_CODEPAGE_UTF32BE					12001	//Unicode (UTF-32 Big endian)
#define FXFM_CODEPAGE_ISO8859_1					28591	//Western European (Latin 1)
#define FXFM_CODEPAGE_ISO8859_2					28592	//Eastern European (Latin 2)
#define FXFM_CODEPAGE_ISO8859_3					28593	//South European (Latin 3)
#define FXFM_CODEPAGE_ISO8859_4					28594	//North European (Latin 4)
#define FXFM_CODEPAGE_ISO8859_5					28595	//Cyrillic
#define FXFM_CODEPAGE_ISO8859_6					28596	//Arabic
#define FXFM_CODEPAGE_ISO8859_7					28597	//Greek
#define FXFM_CODEPAGE_ISO8859_8					28598	//Hebrew
#define FXFM_CODEPAGE_ISO8859_9					28599	//Turkish (Latin 5)
#define FXFM_CODEPAGE_ISO8859_10				28600	//Nordic (Latin 6)
#define FXFM_CODEPAGE_ISO8859_11				28601	//Thai
#define FXFM_CODEPAGE_ISO8859_12				28602	//Devanagari
#define FXFM_CODEPAGE_ISO8859_13				28603	//Baltic (Latin 7)
#define FXFM_CODEPAGE_ISO8859_14				28604	//Celtic (Latin 8)
#define FXFM_CODEPAGE_ISO8859_15				28605	//Latin 9
#define FXFM_CODEPAGE_ISO8859_16				28606	//South-Eastern European (Latin 10)
#define FXFM_CODEPAGE_ISCII_Devanagari			57002	//Devanagari
#define FXFM_CODEPAGE_ISCII_Bengali				57003	//Bengali
#define FXFM_CODEPAGE_ISCII_Tamil				57004	//Tamil
#define FXFM_CODEPAGE_ISCII_Telugu				57005	//Telugu
#define FXFM_CODEPAGE_ISCII_Assamese			57006	//Assamese
#define FXFM_CODEPAGE_ISCII_Oriya				57007	//Oriya
#define FXFM_CODEPAGE_ISCII_Kannada				57008	//Kannada
#define FXFM_CODEPAGE_ISCII_Malayalam			57009	//Malayalam
#define FXFM_CODEPAGE_ISCII_Gujarati			57010	//Gujarati
#define FXFM_CODEPAGE_ISCII_Punjabi				57011	//Punjabi (Gurmukhi)
#define FXFM_CODEPAGE_UTF7						65000	//Unicode (UTF-7)
#define FXFM_CODEPAGE_UTF8						65001	//Unicode (UTF-8)
#define FXFM_CODEPAGE_Unknown					65535	//Unknown
//charset

#define FXFM_CHARSET_ANSI						0	//1252, ANSI
#define FXFM_CHARSET_Default					1	//0, Default
#define FXFM_CHARSET_Symbol						2	//42, Symbol
#define FXFM_CHARSET_MAC_Roman					77	//10000	Mac Roman
#define FXFM_CHARSET_MAC_ShiftJIS				78	//10001	Mac Shift Jis
#define FXFM_CHARSET_MAC_Korean					79	//10003	Mac Korean
#define FXFM_CHARSET_MAC_ChineseSimplified		80	//10008	Mac Chinese Simplified (GBK)
#define FXFM_CHARSET_MAC_ChineseTriditional		81	//10002	Mac Big5
#define FXFM_CHARSET_MAC_Johab					82	//Mac Johab (old)
#define FXFM_CHARSET_MAC_Hebrew					83	//10005	Mac Hebrew
#define FXFM_CHARSET_MAC_Arabic					84	//10004	Mac Arabic
#define FXFM_CHARSET_MAC_Greek					85	//10006	Mac Greek
#define FXFM_CHARSET_MAC_Turkish				86	//10081	Mac Turkish
#define FXFM_CHARSET_MAC_Thai					87	//10021	Mac Thai
#define FXFM_CHARSET_MAC_EasternEuropean		88	//10029	Mac Eastern European (Latin 2)
#define FXFM_CHARSET_MAC_Cyrillic				89	//10007	Mac Cyrillic
#define FXFM_CHARSET_ShiftJIS					128	//932	Shift JIS
#define FXFM_CHARSET_Korean						129	//949	Korean
#define FXFM_CHARSET_Johab						130	//1361	Johab
#define FXFM_CHARSET_ChineseSimplified			134	//936	Chinese Simplified (GBK)
#define FXFM_CHARSET_ChineseTriditional			136	//950	Big5
#define FXFM_CHARSET_MSWin_Greek				161	//1253	Greek
#define FXFM_CHARSET_MSWin_Turkish				162	//1254	Turkish
#define FXFM_CHARSET_MSWin_Vietnamese			163	//1258	Vietnamese
#define FXFM_CHARSET_MSWin_Hebrew				177	//1255	Hebrew
#define FXFM_CHARSET_MSWin_Arabic				178	//1256	Arabic 
#define FXFM_CHARSET_ArabicTraditional			179	//Arabic Traditional (old)
#define FXFM_CHARSET_ArabicUser					180	//Arabic user (old)
#define FXFM_CHARSET_HebrewUser					181	//Hebrew user (old)
#define FXFM_CHARSET_MSWin_Baltic				186	//1257	Baltic
#define FXFM_CHARSET_MSWin_Cyrillic				204	//1251	Cyrillic
#define FXFM_CHARSET_Thai						222	//874	Thai
#define FXFM_CHARSET_MSWin_EasterEuropean		238	//1250	Eastern European
#define FXFM_CHARSET_US							254	//437	PC 437
#define FXFM_CHARSET_OEM						255	//850	OEM
//structure for the mapping table of character sets

FX_WORD	FXFM_GetCodePageFromCharset(FX_BYTE charset);
FX_BYTE FXFM_GetCharsetFromCodePage(FX_WORD codepage);

#endif//_FXFM_CODEPAGE_H_